var database = {
  sex_data: [{
    value: '1',
    label: '男'
  }, {
    value: '2',
    label: '女'
  }],
  card_type: [{
    value: '1',
    label: '身份证'
  }, {
    value: '2',
    label: '护照'
  }, {
    value: '3',
    label: '港澳通行证'
  }, {
    value: '4',
    label: '回乡证'
  }, {
    value: '5',
    label: '台胞证'
  }],
  country_data: [{
    value: 'CN',
    label: '中国',
    callback: () => {
      return 'CN'
    }
  }, {
    value: 'HK',
    label: '中国香港',
    callback: () => {
      return 'HK'
    }
  }, {
    value: 'MO',
    label: '澳门',
    callback: () => {
      return 'MO'
    }
  }, {
    value: 'TW',
    label: '台湾',
    callback: () => {
      return 'TW'
    }
  }, {
    value: 'US',
    label: '美国',
    callback: () => {
      return 'US'
    }
  }, {
    value: 'GB',
    label: '英国',
    callback: () => {
      return 'GB'
    }
  }, {
    value: 'JP',
    label: '日本',
    callback: () => {
      return 'JP'
    }
  }, {
    value: 'CA',
    label: '加拿大',
    callback: () => {
      return 'CA'
    }
  }, {
    value: 'FR',
    label: '法国',
    callback: () => {
      return 'FR'
    }
  }, {
    value: 'KR',
    label: '韩国',
    callback: () => {
      return 'KR'
    }
  }],
  product_type: ['周边游', '国内长线', '国内团', '出境团', '出境短线', '出境长线'],
  getText: function(keyo, value) {
    var data = this[keyo];
    for (var i = 0; i < data.length; i++) {
      if (data[i].label === value) {
        return data[i].label;
      }
    }
  },
  getValue: function(keyo, value) {
    var data = this[keyo];
    for (var i = 0; i < data.length; i++) {
      if (data[i].label === value) {
        return data[i].value;
      }
    }
  }
}
export default database
